package com.xbongbong.pro.applist.pojo.vo;

import com.xbongbong.paas.pojo.ButtonPojo;
import com.xbongbong.paas.field.FieldAttrEntity;
import com.xbongbong.paas.toolbox.helper.PageHelper;
import com.xbongbong.paas.toolbox.util.DateTimeUtil;
import com.xbongbong.paas.toolbox.wrap.BaseVO;
import com.xbongbong.pro.applist.pojo.AppListPojo;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import java.util.List;

/**
 * @author long.rao
 * @version v1.0
 * @date 2019/3/6 21:42
 * @since v1.0
 */
@Getter
@Setter
@ToString
public class ListAppVO extends BaseVO {
    private static final long serialVersionUID = -6426778972275883241L;
    /**
     * 数据集合
     */
    private List<AppListPojo> list;
    /**
     * 数据总数
     */
    private Integer totalCount;
    /**
     * 列表页右上角新建按钮权限
     */
    private Boolean addPermission;

    /**
     * 移动端搜索框隐藏
     */
    private Boolean hideSearch;

    /**
     * 业务类型
     */
    private Integer businessType;

    private List<FieldAttrEntity> headList;

    private PageHelper pageHelper;

    private List<ButtonPojo> topPermissions;

    /**
     * 公海池底部分配、捞取按钮权限
     */
    private List<ButtonPojo> bottomPermissions;

    public ListAppVO() {

    }

    public ListAppVO(List<AppListPojo> list, Integer totalCount) {
        this.list = list;
        this.totalCount = totalCount;
    }

    public ListAppVO(List<AppListPojo> list, Integer totalCount, Boolean addPermission) {
        this.list = list;
        this.totalCount = totalCount;
        this.addPermission = addPermission;
    }

    public ListAppVO(List<AppListPojo> list, Integer totalCount, Boolean addPermission, List<FieldAttrEntity> headList) {
        this.list = list;
        this.totalCount = totalCount;
        this.addPermission = addPermission;
        this.headList = headList;
    }

    public ListAppVO(List<AppListPojo> list, Integer totalCount, Boolean addPermission, List<FieldAttrEntity> headList, Boolean hideSearch) {
        this.list = list;
        this.totalCount = totalCount;
        this.addPermission = addPermission;
        this.headList = headList;
        this.hideSearch = hideSearch;
    }
}
